#include "common/pch.h"

#include <cftc/reflect/class.h>
#include <cftc/reflect/field.h>

#include "cs/cs_message.h"

namespace cs
{

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFInventory, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(displayer_info_id);
		CFT_IMPLEMENT_REFLECT_FIELD(inventory_type);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFPlayerInfo, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(guid);
		CFT_IMPLEMENT_REFLECT_FIELD(name);
		CFT_IMPLEMENT_REFLECT_FIELD(race);
		CFT_IMPLEMENT_REFLECT_FIELD(class_);
		CFT_IMPLEMENT_REFLECT_FIELD(gender);
		CFT_IMPLEMENT_REFLECT_FIELD(skin);
		CFT_IMPLEMENT_REFLECT_FIELD(face);
		CFT_IMPLEMENT_REFLECT_FIELD(hair_style);
		CFT_IMPLEMENT_REFLECT_FIELD(hair_color);
		CFT_IMPLEMENT_REFLECT_FIELD(facial_hair);
		CFT_IMPLEMENT_REFLECT_FIELD(level);
		CFT_IMPLEMENT_REFLECT_FIELD(zone);
		CFT_IMPLEMENT_REFLECT_FIELD(map);
		CFT_IMPLEMENT_REFLECT_FIELD(x);
		CFT_IMPLEMENT_REFLECT_FIELD(y);
		CFT_IMPLEMENT_REFLECT_FIELD(z);
		CFT_IMPLEMENT_REFLECT_FIELD(guild_id);
		CFT_IMPLEMENT_REFLECT_FIELD(char_flags);
		CFT_IMPLEMENT_REFLECT_FIELD(first_login);
		CFT_IMPLEMENT_REFLECT_FIELD(pet_display_id);
		CFT_IMPLEMENT_REFLECT_FIELD(pet_level);
		CFT_IMPLEMENT_REFLECT_FIELD(pet_family);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(inventory_list, R"(wow:"list_size_type:carray")");
		CFT_IMPLEMENT_REFLECT_FIELD(reserve1);
		CFT_IMPLEMENT_REFLECT_FIELD(reserve2);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFPosition, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(x);
		CFT_IMPLEMENT_REFLECT_FIELD(y);
		CFT_IMPLEMENT_REFLECT_FIELD(z);
		CFT_IMPLEMENT_REFLECT_FIELD(o);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFMovementInfo::MFMovementFlagOnTransport, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(guid);
		CFT_IMPLEMENT_REFLECT_FIELD(pos);
		CFT_IMPLEMENT_REFLECT_FIELD(time);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFMovementInfo::MFMovementFlagSwimming, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(pitch);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFMovementInfo::MFMovementFlagFalling, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(velocity);
		CFT_IMPLEMENT_REFLECT_FIELD(sinAngle);
		CFT_IMPLEMENT_REFLECT_FIELD(cosAngle);
		CFT_IMPLEMENT_REFLECT_FIELD(xyspeed);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(MFMovementInfo, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(move_flags);
		CFT_IMPLEMENT_REFLECT_FIELD(time);
		CFT_IMPLEMENT_REFLECT_FIELD(pos);
		CFT_IMPLEMENT_REFLECT_FIELD(flag_ontransport);
		CFT_IMPLEMENT_REFLECT_FIELD(flag_swimming);
		CFT_IMPLEMENT_REFLECT_FIELD(fall_time);
		CFT_IMPLEMENT_REFLECT_FIELD(flag_falling);
		CFT_IMPLEMENT_REFLECT_FIELD(u_unk1);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(CMAuthSession, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(built_number_client);
		CFT_IMPLEMENT_REFLECT_FIELD(unk2);
		CFT_IMPLEMENT_REFLECT_FIELD(account);
		CFT_IMPLEMENT_REFLECT_FIELD(client_seed);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(digest, R"(wow:"fix_string_len:20")");
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(SMAuthResponse, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(code);
		CFT_IMPLEMENT_REFLECT_FIELD(billing_time_remaining);
		CFT_IMPLEMENT_REFLECT_FIELD(billing_plan_flags);
		CFT_IMPLEMENT_REFLECT_FIELD(billing_time_rested);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(CMCharEnum, cftc::reflect::Object);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(SMCharEnum, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(char_list, R"(wow:"list_size_type:uint8")");
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(SMAuthChallenge, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD(seed);
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(CMPlayerLogin, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(player_guid, R"()");
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(SMLoginVerifyWorld, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(map_id, R"()");
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(pos, R"()");
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(SMAccountDataTimes, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(data, R"()");
	CFT_IMPLEMENT_REFLECT_CLASS_END();

	CFT_IMPLEMENT_REFLECT_CLASS_BEGIN(SMTrigggerClinematic, cftc::reflect::Object);
		CFT_IMPLEMENT_REFLECT_FIELD_ANNOTATION(CinematicSequenceId, R"()");
	CFT_IMPLEMENT_REFLECT_CLASS_END();
}